/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package com.farmcode.api.runtime.metadata;

import java.io.Serializable;

/**
 *
 * @author oiprado
 */
public class ObjectInfoSpc implements ObjectInfo, Serializable {

    private String schema;
    private String name;
    private String type;
    private boolean used;
    private String className;

    public ObjectInfoSpc() {
    }

    public ObjectInfoSpc(String schema, String name, String type, boolean used, String className) {
        this.name = name;
        this.type = type;
        this.used = used;
        this.className = className;
        this.schema = schema;
    }
    
    public ObjectInfoSpc(String name, String type, boolean used, String className) {
        this.name = name;
        this.type = type;
        this.used = used;
        this.className = className;
    }
    
    private ChildCollection childs = new ChildCollection();
    
    @Override
    public String getName() {
        return name;
    }

    @Override
    public void setName(String name) {
        this.name = name;
    }

    @Override
    public String getType() {
        return type;
    }

    @Override
    public void setType(String type) {
        this.type = type;
    }   

    @Override
    public String getClassName() {
        return className;
    }

    @Override
    public void setClassName(String className) {
        this.className = className;
    }

    @Override
    public boolean isUsed() {
        return used;
    }

    @Override
    public void setUsed(boolean used) {
        this.used = used;
    }

    @Override
    public ChildCollection getChilds() {
        return childs;
    }

    @Override
    public void setChilds(ChildCollection childs) {
        this.childs = childs;
    }

    /**
     * @return the schema
     */
    @Override
    public String getSchema() {
        return schema;
    }

    /**
     * @param schema the schema to set
     */
    @Override
    public void setSchema(String schema) {
        this.schema = schema;
    }

    @Override
    public String toString() {
        return "[object = " + getName() + ", type = "+getType()+"]";
    }
    
    
    
}
